﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Gasco.Business.Services;
using Gasco.DataAccess;

public partial class Controls_company_contact_view : System.Web.UI.UserControl
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Request.QueryString["id"] != null)
        {
            ContactService cs = new ContactService();
            contact c = cs.GetContactById(Convert.ToInt16(Request.QueryString["id"]));
            lbNameValue.Text = c.name;
            lbRegisterCodeValue.Text = c.company_contact.register_code;
            lbCEONameValue.Text = c.company_contact.ceo_name;
            lbCEOTelValue.Text = c.company_contact.ceo_tel;
            lbCEOMobileValue.Text = c.company_contact.ceo_mobile;
            lbCORRNameValue.Text = c.company_contact.corr_name;
            lbCORRTelValue.Text = c.company_contact.corr_tel;
            lbCORRMobileValue.Text = c.company_contact.corr_mobile;
            lbFaxValue.Text = c.fax;
            lbEmailValue.Text = c.email;
            lbAccountInfoValue.Text = c.account_info;
            lbAddressValue.Text = c.address;
        }
    }
}
